namespace CLELCore.Assembly.CLELInstructions
{
	public class Unaligned : ObjectModel
	{
		private byte _align;
		public override int Length
		{
			get
			{
				return 3;
			}
		}
		public byte Align
		{
			get
			{
				return _align;
			}
			set
			{
				_align = value;
			}
		}
		public Unaligned(byte align) : base(CLELOpcode.OBJECTMODEL,CLELOpcode.UNALIGNED)
		{
			_align = align;
		}

		public override byte[] GetBytes(bool little_endian)
		{
			byte[] ret = new byte[3];
			ret[0] = CLELOpcode.OBJECTMODEL;
			ret[1] = CLELOpcode.UNALIGNED;
			ret[2] = _align;
			return ret;
		}
		
		public override string ToString()
		{
			return "unaligned. " + _align;
		}
	}
}
